package cn.com.do4u.domain;

import com.jfinal.plugin.activerecord.Model;

import java.util.List;

/**
 * Created by chenyu on 15/12/8.
 */
public class Radcheck extends Model<Radcheck> {
   public static final Radcheck me = new Radcheck();

   /**
    * 使用
    * @param userName
    * @param password
    * @return
    */
   public boolean login(String userName ,String password){
      List<Radcheck> list = me.find("select * from radcheck where username = ? and value = ?",userName,password);
      if(list.size() == 1){
         return true;
      }else {
         return false;
      }
   }
}
